'''
Created on 19/04/2010

@author: Mar
'''
import queue

class Scheduler:
    
    def __init__(self):
        self.sleptPCBs =  []  
       
    def nextPCB(self):
        return self.readyQueue.get()
    
    def getReadyQueue(self):
        return self.readyQueue
        
    def isQuantum(self):
        return False    
       
    def getQuantum(self):
        return 0
    
    def sendDadToReady (self, aPCB):
        self.sleptPCBs.remove(aPCB)
        aPCB.toReady()    
        self.readyQueue.put(aPCB)
        
        
        
    def sendToSleep(self, aPCB):
        self.sleptPCBs.append(aPCB)
        
    